Detection devices such as Hall effect sensors and encoders can be used to generate quadrature phase signals. A rotating shaft attached to a motor is frequently connected to such a detection device.
A Hall effect sensor is a solid state detection device that varies its output voltage in response to a magnetic field. The Hall effect sensor operates as an analog transducer that returns a signal corresponding to the position of the magnet. With a known magnetic field, the magnet's distance from the Hall plate can be determined, or using groups of sensors, the relative position of the magnet can be deduced.
Encoders are commonly used to sense the motion of the shaft, in a wide range of applications such as in pulleys on top of cable car towers, or in a computer mouse. It is common for encoders to incorporate an electronic circuit that senses rotation of a rotating wheel that includes a series of evenly spaced apart openings. The electronic circuit counts each time the graduated disc permits light through one of the openings, and then is blocked by an opaque surface. The circuit determines the position of the shaft and counts the revolutions of the shaft.
Detection devices such as Hall effect sensors and encoders typically output a pulse string in response to the amount of rotational displacement of the shaft. Optical encoders can produce quadrature phase signals representative of linear or rotational displacement or some other variable parameter directly or after wave shaping. The quadrature phase signals may be processed to interface with a computer such as a microprocessor. In certain applications where devices of this type are intended to detect rotation, it is necessary to detect the rate of rotation of the target and the direction of rotation. If the shaft suddenly reverses direction, the sensor must be able to detect that reversal. This type of sensor can be found in automatic braking systems and other systems where speed and direction of rotation of a target must be determined.
Quadrature sensing involves the use of two signals that are offset from each other by 90 degrees. A comparison of the signals will provide meaningful information with regard to the position and direction of travel of a target. Using two digital outputs in quadrature is useful to determine direction and a change in angle of a motor shaft.
To determine the direction of rotation, the relative phase between the quadrature outputs are determined. One way to do this is to check the value of the first quadrature output at every edge of the second quadrature output. If the first signal is high when a rising edge is detected, then the first signal is ahead by a quarter period. Motion in the opposite direction is detected when the first signal is low when a rising edge is detected on the second output.
U.S. Patent Application Publication No. 2010/0158180 shows a method and apparatus for increasing jitter tolerance. U.S. Pat. No. 8,001,848 shows a method and device for measuring torque using sensor signals with a rotatable shaft. U.S. Pat. No. 5,315,620 shows a method for detecting and correcting phase errors. U.S. Pat. No. 5,365,184 shows a method and apparatus for quadrature phase processing to provide high dynamic range and phase recovery at reduced sample rates. U.S. Pat. No. 6,470,291 shows a method of providing accurate measurement of rotational velocity and an adequate bandwidth for servo control as a function of the measurement over a wide range of velocities.
Errors in these types of systems may occur, however, when the microprocessor cannot sample at a rate high enough to capture all of the phase changes of the output to determine the direction, either due to the limited bandwidth of the microprocessor, or the speed of the motor, or both. Also, errors are more prone to occur when the phases of the output are separated by less than 90 electrical degrees. Therefore, there exists a need for improvement in the art.